
<template>
  <RouterLink :to="{ name: 'Demo' }">Demo</RouterLink>
  <RouterLink :to="{ name: 'StuShow' }">StuShow</RouterLink>
<br>
  <button @click="toPage('/')">Demo</button>
  <button @click="toPage('/stuShow')">StuShow</button>

  <RouterView />
</template>

<script setup lang="ts">
import { useRouter } from 'vue-router'

//
const router = useRouter();

const toPage = (path: string) => {
  //
  router.push(path);
}

</script>
